# -*- coding:utf-8 -*-
"""
Author：Administrator
Date:2023年02月23日
"""
import docx

myDocument=docx.Document("散文名篇.docx")
# 获取word文件的第2个段落
myParagraph1=myDocument.paragraphs[1]._element
myParagraph1.getparent().remove(myParagraph1)

myParagraph2=myDocument.paragraphs[2]._element
myParagraph2.getparent().remove(myParagraph2)


myDocument.save("02散文名篇.docx")